<nz-layout class="app-layout">
  <nz-sider class="menu-sidebar"
            nzCollapsible
            nzWidth="256px"
            nzBreakpoint="md"
            [(nzCollapsed)]="isCollapsed"
            [nzTrigger]="null">
    <div class="sidebar-logo">
      <a>
        <h1>信息管理与智能分析系统</h1>
      </a>
    </div>
    <ul nz-menu nzTheme="dark" nzMode="inline" [nzInlineCollapsed]="isCollapsed">
      <li nz-submenu nzOpen nzTitle="学习笔记" nzIcon="dashboard">
        <ul>
          <li nz-menu-item nzMatchRouter>
            <a routerLink="/loglist">学习信息记录与管理</a>
          </li>
          <li nz-menu-item nzMatchRouter>
            <a routerLink="/filerecord">文档管理</a>
          </li>
        </ul>
      </li>
      <li nz-submenu nzOpen nzTitle="系统管理" nzIcon="dashboard">
        <ul>
          <li *ngIf="isAdministrator" nz-menu-item nzMatchRouter>
            <a routerLink="/user">用户管理</a>
          </li>
          <li *ngIf="isAdministrator" nz-menu-item nzMatchRouter>
            <a routerLink="/notice">邮件发送记录</a>
          </li>
          <li *ngIf="isAdministrator" nz-menu-item nzMatchRouter>
            <a routerLink="/system">系统设置</a>
          </li>
          <li nz-menu-item nzMatchRouter>
            <a routerLink="/personal">个人设置</a>
          </li>
        </ul>
      </li>
    </ul>
  </nz-sider>
  <nz-layout>
    <nz-header>
      <div class="app-header">
        <span class="header-trigger" (click)="isCollapsed = !isCollapsed">
            <span class="trigger"
                  nz-icon
                  [nzType]="isCollapsed ? 'menu-unfold' : 'menu-fold'"
            ></span>

        </span>
        <span style="color: red;font-family: 楷体;font-size:22px;display: -moz-inline-box;display: inline-block">&nbsp;&nbsp;路虽远，行则将至;事虽难，做则必成✍️</span>
        <span style="font-size:18px;float: right">{{ userDetails.name }}<a style="font-size: 16px" nz-button
                                                                           nzType="link"
                                                                           (click)="logout()">登出</a></span>
      </div>
    </nz-header>
    <nz-content>
      <div class="inner-content">
        <router-outlet></router-outlet>
      </div>
    </nz-content>
  </nz-layout>
</nz-layout>

